{include file="public/header" /}
<body>

	
	<!--header start-->
    <header>
    	<div class="header">
        	<a href="javascript:history.go(-1);" class="fan"></a>
        	<h1>个人资料</h1>
        </div>
    </header>
    <!--header end-->
    
    <!--main start-->
    <div class="my_one">
    	<img src="{$info['head_img']}" class="img">
        <div class="left">
            <span class="name">{$info['nickname']}</span>
            <span class="wxID">微信号：{$info['wx_code']}</span>
            <span class="dz">{$info['address']}</span>
        </div>
        <span id="note" data-uid="{$info['id']}" class="ly">
        	对她留言
        </span>
    </div>
    
    <div class="in_one">
        <i class="i1"></i>
        <span>个人资料</span>
    </div>
    <ul class="in_two"> 
        <li>
            <span class="ll">出生日期: </span>
            <span class="rr">{$info['birth']}</span>

        </li>
        <li>
            <span class="ll">家乡:</span>
            <span class="rr">{$info['home_province']}/{$info['home_city']}</span>

        </li>
        <li>
            <span class="ll">学历:</span>
            <span class="rr">{$info['offer']}</span>
        </li>
        <li>
            <span class="ll">毕业院校:</span>
            <span class="rr">{$info['college']}</span>
        </li>
        <li>
            <span class="ll">工作单位:</span>
            <span class="rr">{$info['work']}</span>
        </li>
        <li>
            <span class="ll">身高:</span>
            <span class="rr">{$info['height']}cm</span>
        </li>
    </ul>
    
    <div class="in_one">
        <i class="i2"></i>
        <span>择偶标准</span>
    </div>
    <ul class="in_two"> 
        <li>
            <span class="ll">年龄:</span>
            <span class="rr">{$info['min_age']} ~ {$info['max_age']}岁</span>
        </li>
        <li>
            <span class="ll">学历:</span>
            <span class="rr">{$info['other_offer']}</span>

        </li>
        <li>
            <span class="ll">身高:</span>
            <span class="rr">{$info['min_height']} ~ {$info['max_height']}cm</span>
        </li>
    </ul>
    
    <div class="in_one">
        <i class="i3"></i>
        <span>兴趣爱好</span>
    </div>
    <div class="in_two">
        <div class="desc">
            简介：{$info['habit']}
        </div>
    </div>
    
    <div class="in_one">
        <i class="i4"></i>
        <span>家庭介绍</span>
    </div>
    <div class="in_two">
        <div class="desc">
            {$info['home_intro']}
        </div>
    </div>
    
    <div class="in_one">
        <i class="i5"></i>
        <span>个人介绍</span>
    </div>
    <div class="in_two">
        <div class="desc">
            {$info['self_intro']}
        </div>
    </div>
    <!--main end-->
    
    <script type="text/javascript">
    $(function(){
		$(".btn_bj").click(function(){
			var i=$(".btn_bj").index(this);
			if($(this).val()=="编辑"){
				$(this).val("保存");
				$(".in_two:eq("+i+") .rr").hide();	
				$(".in_two:eq("+i+") .desc").hide();	
				$(".in_two:eq("+i+") .rr_xiang").show();
				$(".in_two:eq("+i+") .txt_js").show();			
			}
			else{
				$(this).val("编辑");
				$(".in_two:eq("+i+") .rr").show();	
				$(".in_two:eq("+i+") .desc").show();	
				$(".in_two:eq("+i+") .rr_xiang").hide();
				$(".in_two:eq("+i+") .txt_js").hide();	
			}
		})
        $("#note").click(function(){
            var uid = $(this).data('uid');
            layer.prompt({title: '填写留言，并确认', formType: 2}, function(text, index){
                layer.close(index);
                if(text){
                    // layer.alert(uid)
                    $.post("{:url('index/Note/add')}", {'uid':uid,'content':text}, function (res) {
                        if (res.code == 1) {
                            layer.msg(res.msg, {time: 1000, icon: 1});
                        } else {
                            layer.msg(res.msg, {time: 1000, icon: 2});
                        }
                    });
                }
            });
        })
	})
    </script>
    
</body>
</html>
